package com.sservice.model.dao;

import com.sservice.model.entity.PurchaseOrderBill;
import com.sservice.model.vo.PurchaseOrderBillVo;

import java.util.List;

public interface PurchaseOrderBillMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(PurchaseOrderBill record);

    int insertSelective(PurchaseOrderBill record);

    PurchaseOrderBill selectByPrimaryKey(Integer id);

    PurchaseOrderBillVo detailById(Integer id);

    int updateByPrimaryKeySelective(PurchaseOrderBill record);

    /**
     *  根据no 更新
     * @param record
     * @return
     */
    int updateByNoSelective(PurchaseOrderBill record);

    int queryCurrentDayCount();

    String queryCurrentDayMaxNo();

    int updateByPrimaryKey(PurchaseOrderBill record);

    int queryCount(PurchaseOrderBillVo record);

    List<PurchaseOrderBillVo> queryByPage(PurchaseOrderBillVo record);

    /**
     *  通过no 查找
     * @param record
     * @return
     */
    List<PurchaseOrderBillVo> queryDetailByNo(PurchaseOrderBillVo record);

    //  查询发票
    List<PurchaseOrderBillVo> queryPaperByPage(PurchaseOrderBillVo record);

    List<PurchaseOrderBillVo> queryCanSell(PurchaseOrderBillVo record);

    List<PurchaseOrderBillVo> queryCanSend(PurchaseOrderBillVo record);

    List<PurchaseOrderBillVo> queryCanSellUnion(PurchaseOrderBillVo record);

    int selectByStoreId(PurchaseOrderBill record);

    int queryByStoreId(String storeId);

}